package cn.initcap.designpattern.pattern.behavioral.observer.guavatest;

import com.google.common.eventbus.Subscribe;

/**
 * guava注解实现观察者模式
 *
 * @author initcap
 * @date Created in 2018/10/14 PM8:34.
 */
public class GuavaEvent {

    @Subscribe
    public void subscribe(String str) {
        // 业务逻辑
        System.out.println("执行subscribe方法，传入参数：" + str);
    }

}
